<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<html>
<head>
<%@ include file="/header_inc.jsp"%>
<script type="text/javascript" src="/js/checkCode.js"></script>
<title>后台登录</title>
<script>
	function submitForm() {
/* 
			document.getElementById('input').focus();	//定位值文本框
			
			document.getElementById("input").value = "";//清空文本框  
 */
			$('#login').form('submit', {
				url : '/shoeHouse/userInfo/login',
				dataType : 'json',
				success : function(result) {
					var json = $.parseJSON(result);
					if (json.success == 0) {
						 $.messager.progress({
			                 text : "登录成功,正在跳转到系统主界面"
			            });
						window.location.href = "/shoeHouse/userInfo/main";
					} 
					 else { 
						getTip("提示",json.msg,700);
					
					}
				}
			});
		}



	function clearForm() {
		$('#login').form('clear');
	}
	
	function checkInfo() {
			if (event.keyCode==13) {	//回车
				 submitForm();
			 }	
	}

	
</script>
<style type="text/css">
#code {
	font-family: Arial;
	font-style: normal;
	font-weight: bold;
	border: 0;
	letter-spacing: 2px;
	color: blue;
}
</style>
</head>
<body onload="createCode()"  style="width:100%;height: 100%;">
	<div id="w" class="easyui-window" title="shoeHouse后台登录" resizable="false"
		closable="false" minimizable="false" maximizable="false"
		collapsible="false" data-options="iconCls:'icon-save'"
		style="width: 450px; height: 225px; padding: 3px;">
		<table>
			<tr>
				<td>
					<div style="padding: 1px 0px 5px 20px" align="left">
						<img src="${ctx}/images/mini.png" width="110" height="110"
							style="background-repeat: no-repeat">
					</div>
				</td>
				<td><br>
					<div style="padding: 1px 0px 5px 20px" align="right">
						<form id="login" method="post">
							<table cellpadding="3" border="0">
								<tr height="30">
									<td>用户名:&nbsp;&nbsp;&nbsp;</td>
									<td><input class="easyui-validatebox textbox" value="" 
										type="text" name="username" data-options="required:true"
										maxlength="15" style="width: 160px; height: 25px"></input></td>
								</tr>
								<tr height="30">
									<td>密&nbsp;&nbsp;&nbsp;码:&nbsp;&nbsp;&nbsp;</td>
									<td><input class="easyui-validatebox textbox" 
										type="password" value="" name="password"
										data-options="required:true" maxlength="16"
										style="width: 160px; height: 25px"></input></td>
								</tr>
								<!-- <tr height="30">
									<td>验证码:&nbsp;&nbsp;&nbsp;</td>
									<td><input type="button" style="width: 70px; height: 25px"
										id="code" onclick="createCode()" /><input
										class="easyui-validatebox textbox" type="text" id="input"
										onkeypress="checkInfo();" name="code" maxlength="4"
										data-options="required:true"
										style="width: 80px; height: 25px; margin-left: 2px; vertical-align: middle"></input></td>
								</tr> -->
							</table>
						</form>

						<div style="text-align: center; padding: 2px">
							<a href="javascript:void(0)" class="easyui-linkbutton"
								style="width: 90px; height: 25px" onclick="submitForm()">&nbsp;登&nbsp;录&nbsp;</a>
							<a href="javascript:void(0)" class="easyui-linkbutton"
								style="width: 90px; height: 25px" onclick="clearForm()">&nbsp;取&nbsp;消&nbsp;</a>
						</div>
					</div></td>
			</tr>


		</table>

	</div>

</body>
</html>